/*
 * @(#)SmsService.java 2021年3月15日
 *
 * Copyright (c) 2010 by rayootech.com. All rights reserved.
 */
package com.nuctech.user.service;

import org.apache.rocketmq.spring.annotation.RocketMQMessageListener;
import org.apache.rocketmq.spring.core.RocketMQListener;
import org.springframework.stereotype.Service;

import com.nuctech.common.entity.Order;

import lombok.extern.slf4j.Slf4j;

/**
 * 短信业务接口
 * 
 * @author lilu
 * @date 2021年3月15日
 * @since 1.0.0
 */
@Slf4j
@Service
@RocketMQMessageListener(consumerGroup = "sca-order", topic = "order-topic")
public class SmsService implements RocketMQListener<Order> {

	/**
	 * 消费逻辑
	 * @see org.apache.rocketmq.spring.core.RocketMQListener#onMessage(java.lang.Object)
	 */
	@Override
	public void onMessage(Order message) {
		log.info("接收到一个订单信息:{}，接下来可以发送短信通知了", message);
	}

}
